#ifndef XXXINFO_H
#define XXXINFO_H

#include <stdbool.h>
#include <ext2fs/ext2fs.h>
#include "xxx_types.h"

extern int init_empty_xxx_info(struct xxx_info *info, const struct xxx_super_area *sa);
extern int load_xxx_info(struct xxx_info *info, const char *path);

extern int read_xxx_info(struct xxx_info *info);
extern int read_xxx_info2(struct xxx_info *info, ext2_file_t opened_file);

extern int write_xxx_info(const struct xxx_info *info);
extern int write_xxx_info2(const struct xxx_info *info, ext2_file_t opened_file);

extern void free_xxx_info(struct xxx_info *info);
extern void free_xxx_info_buff(struct xxx_info *info);

int three_in_one(const struct xxx_info *info, const char *filepath,  char *filename, char *dirpath);

#endif // XXXINFO_H

